package com.huishu.goods.controller;


import com.huishu.commons.pojo.Result;
import com.huishu.goods.pojo.model.ProductLabelDO;
import com.huishu.goods.service.ProductLabelService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
* @author generator@ljj
* @since 2023-04-10
*/
@RestController
@RequestMapping("/product-label")
@Slf4j
public class ProductLabelController {


    @Autowired
    private ProductLabelService productLabelService;


    @PostMapping("/update")
    public Result update(@RequestBody ProductLabelDO productLabelDO) {
        return productLabelService.updateById(productLabelDO) ? Result.success() : Result.fail();
    }
}
